package com.example.demo.model;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

import org.apache.commons.lang3.StringUtils;
import org.hibernate.annotations.GenericGenerator;
import org.springframework.beans.factory.config.BeanDefinition;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;


@Component("sysRoleResource.model")
@Scope(BeanDefinition.SCOPE_PROTOTYPE)
@Entity(name = "sysRoleResource")
@Table(name = "sys_role_resource")
public class SysRoleResourceModel   implements Serializable{
	
	private static final long serialVersionUID = 1L;
	
	
	
	@Id
	@GeneratedValue(generator = "uuid")
	@GenericGenerator(name = "uuid", strategy = "uuid")
	@Column(name = "id")
	private String  id;
	
	/** 内部角色ID  **/
	private String  roleId;
	
	/** 内部资源ID  **/
	private String  resourceId;
    
	public String getId() {
		return id;
	}
	
	public void setId(String id) {
		this.id = id;
	}
	
    @Column(name = "role_id")
    public String getRoleId() {
        return StringUtils.isBlank(roleId) ? roleId : roleId.trim();
    }
    public void setRoleId(String roleId) {
        this.roleId = roleId;
    }
    
    
    @Column(name = "resource_id")
    public String getResourceId() {
        return StringUtils.isBlank(resourceId) ? resourceId : resourceId.trim();
    }
    public void setResourceId(String resourceId) {
        this.resourceId = resourceId;
    }
    
    
}